import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.math.BigInteger;
import java.util.*;

/**
 * @author Egor Kulikov (egor@egork.net)
 */
public class SquaGame {
	@SuppressWarnings({"FieldCanBeLocal", "UnusedDeclaration"})
	private InputReader in;
	private PrintWriter out;

	private static class Side implements Comparable<Side> {
		public static final int LEFT = 0;
		public static final int RIGHT = 1;
		public static final int TOP = 2;
		public static final int BOTTOM = 3;
		private final int type;
		private final int coordinate;
		private final int index;

		private Side(int type, int coordinate, int index) {
			this.type = type;
			this.coordinate = coordinate;
			this.index = index;
		}

		public int compareTo(Side o) {
			return coordinate - o.coordinate;
		}
	}

	private void solve() {
		int squareCount = in.readInt();
		Side[] left = new Side[squareCount];
		Side[] right = new Side[squareCount];
		Side[] horizontal = new Side[squareCount * 2];
		for (int i = 0; i < squareCount; i++) {
			int x = in.readInt();
			int y = in.readInt();
			int length = in.readInt();
			left[i] = new Side(Side.LEFT, x, i);
			right[i] = new Side(Side.RIGHT, x + length, i);
			horizontal[2 * i] = new Side(Side.BOTTOM, y, i);
			horizontal[2 * i + 1] = new Side(Side.TOP, y + length, i);
		}
		int[] parent = new int[squareCount];
		Arrays.fill(parent, -1);
		@SuppressWarnings({"unchecked"})
		List<Integer>[] children = new List[squareCount];
		for (int i = 0; i < squareCount; i++)
			children[i] = new ArrayList<Integer>();
		Arrays.sort(horizontal);
		buildStructure(left, right, horizontal, parent, children);
		int[] order = new int[squareCount];
		int rightIndex = 0;
		for (int i = 0; i < squareCount; i++) {
			if (parent[i] == -1)
				order[rightIndex++] = i;
		}
		for (int i = 0; i < squareCount; i++) {
			int current = order[i];
			for (int child : children[current])
				order[rightIndex++] = child;
		}
		int[] nimber = new int[squareCount];
		for (int i = squareCount - 1; i >= 0; i--) {
			int index = order[i];
			if (children[index].isEmpty())
				nimber[index] = 1;
			else {
				nimber[index] = 0;
				for (int child : children[index])
					nimber[index] ^= nimber[child];
				nimber[index]++;
			}
		}
		int totalNimber = 0;
		for (int i = 0; i < squareCount; i++) {
			if (parent[i] == -1)
				totalNimber ^= nimber[i];
		}
		if (totalNimber == 0)
			out.println("Fit");
		else {
			boolean[] winnable = new boolean[squareCount];
			int[] passedNimber = new int[squareCount];
			Arrays.fill(passedNimber, -1);
			for (int i = 0; i < squareCount; i++) {
				int index = order[i];
				if (parent[index] == -1)
					passedNimber[index] = totalNimber ^ nimber[index];
				if (passedNimber[index] == -1)
					continue;
				if (passedNimber[index] == 0) {
					winnable[index] = true;
				} else {
					passedNimber[index]--;
					passedNimber[index] ^= nimber[index] - 1;
					for (int child : children[index])
						passedNimber[child] = passedNimber[index] ^ nimber[child];
				}
			}
			out.print("Fat ");
			for (int i = 0; i < squareCount; i++) {
				if (winnable[i]) {
					out.println(i + 1);
					return;
				}
			}
		}
	}

	private void buildStructure(Side[] left, Side[] right, Side[] horizontal, int[] parent, List<Integer>[] children) {
		NavigableSet<Side> vertical = new TreeSet<Side>();
		for (Side horizontalSide : horizontal) {
			if (horizontalSide.type == Side.TOP) {
				vertical.remove(left[horizontalSide.index]);
				vertical.remove(right[horizontalSide.index]);
			} else {
				Side last = vertical.floor(left[horizontalSide.index]);
				if (last != null && last.type == Side.LEFT) {
					parent[horizontalSide.index] = last.index;
					children[last.index].add(horizontalSide.index);
				} else if (last != null) {
					parent[horizontalSide.index] = parent[last.index];
					if (parent[horizontalSide.index] != -1)
						children[parent[last.index]].add(horizontalSide.index);
				}
				vertical.add(left[horizontalSide.index]);
				vertical.add(right[horizontalSide.index]);
			}
		}
	}

	private void checkWinnable(List<Integer>[] children, int[] nimber, int index, boolean[] winnable, int totalNimber) {
		if (totalNimber == 0) {
			winnable[index] = true;
			return;
		}
		totalNimber--;
		totalNimber ^= nimber[index] - 1;
		for (int child : children[index])
			checkWinnable(children, nimber, child, winnable, totalNimber ^ nimber[child]);
	}

	public static void main(String[] args) {
		new SquaGame().run();
	}

	private SquaGame() {
		@SuppressWarnings({"UnusedDeclaration"})
		String id = getClass().getName().toLowerCase();
		//noinspection EmptyTryBlock
		try {
//			System.setIn(new FileInputStream(id + ".in"));
//			System.setOut(new PrintStream(new FileOutputStream(id + ".out")));
//			System.setIn(new FileInputStream("input.txt"));
//			System.setOut(new PrintStream(new FileOutputStream("output.txt")));
		} catch (Exception e) {
			throw new RuntimeException(e);
		}
		in = new InputReader(System.in);
		out = new PrintWriter(System.out);
	}

	private void run() {
		//noinspection InfiniteLoopStatement
//		while (true)
		int testCount = in.readInt();
		for (int i = 0; i < testCount; i++)
			solve();
		exit();
	}

	@SuppressWarnings({"UnusedDeclaration"})
	private void exit() {
		out.close();
		System.exit(0);
	}

	@SuppressWarnings({"UnusedDeclaration"})
	private static class InputReader {
		private InputStream stream;
		private byte[] buf = new byte[1024];
		private int curChar, numChars;

		public InputReader(InputStream stream) {
			this.stream = stream;
		}

		public int read() {
			if (numChars == -1)
				throw new InputMismatchException();
			if (curChar >= numChars) {
				curChar = 0;
				try {
					numChars = stream.read(buf);
				} catch (IOException e) {
					throw new InputMismatchException();
				}
				if (numChars <= 0)
					return -1;
			}
			return buf[curChar++];
		}

		public int readInt() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			int res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public long readLong() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			long res = 0;
			do {
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			} while (!isSpaceChar(c));
			return res * sgn;
		}

		public String readString() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			StringBuffer res = new StringBuffer();
			do {
				res.appendCodePoint(c);
				c = read();
			} while (!isSpaceChar(c));
			return res.toString();
		}

		private boolean isSpaceChar(int c) {
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		private String readLine0() {
			StringBuffer buf = new StringBuffer();
			int c = read();
			while (c != '\n' && c != -1) {
				if (c != '\r')
					buf.appendCodePoint(c);
				c = read();
			}
			return buf.toString();
		}

		public String readLine() {
			String s = readLine0();
			while (s.trim().length() == 0)
				s = readLine0();
			return s;
		}

		public String readLine(boolean ignoreEmptyLines) {
			if (ignoreEmptyLines)
				return readLine();
			else
				return readLine0();
		}

		public BigInteger readBigInteger() {
			try {
				return new BigInteger(readString());
			} catch (NumberFormatException e) {
				throw new InputMismatchException();
			}
		}

		public char readCharacter() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			return (char) c;
		}

		public double readDouble() {
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-') {
				sgn = -1;
				c = read();
			}
			double res = 0;
			while (!isSpaceChar(c) && c != '.') {
				if (c == 'e' || c == 'E')
					return res * Math.pow(10, readInt());
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			if (c == '.') {
				c = read();
				double m = 1;
				while (!isSpaceChar(c)) {
					if (c == 'e' || c == 'E')
						return res * Math.pow(10, readInt());
					if (c < '0' || c > '9')
						throw new InputMismatchException();
					m /= 10;
					res += (c - '0') * m;
					c = read();
				}
			}
			return res * sgn;
		}

		public int[] readIntArray(int size) {
			int[] array = new int[size];
			for (int i = 0; i < size; i++)
				array[i] = readInt();
			return array;
		}

		public long[] readLongArray(int size) {
			long[] array = new long[size];
			for (int i = 0; i < size; i++)
				array[i] = readLong();
			return array;
		}

		public double[] readDoubleArray(int size) {
			double[] array = new double[size];
			for (int i = 0; i < size; i++)
				array[i] = readDouble();
			return array;
		}

		public String[] readStringArray(int size) {
			String[] array = new String[size];
			for (int i = 0; i < size; i++)
				array[i] = readString();
			return array;
		}

		public char[][] readTable(int rowCount, int columnCount) {
			char[][] table = new char[rowCount][columnCount];
			for (int i = 0; i < rowCount; i++) {
				for (int j = 0; j < columnCount; j++)
					table[i][j] = readCharacter();
			}
			return table;
		}

		public void readIntArrays(int[]... arrays) {
			for (int i = 0; i < arrays[0].length; i++) {
				for (int j = 0; j < arrays.length; j++)
					arrays[j][i] = readInt();
			}
		}
	}
}
